<!DOCTYPE html>
<html lang="en">
<head>
    <!-- jsp文件头和头部 -->
<#include '../top.ftl'>
</head>
<script type="text/javascript" src="/static/js/jquery.form.js"></script>
<script type="text/javascript">
    function search() {
        $("#userForm").submit();
    }
</script>
<body>

<div class="container-fluid" id="main-container">
    <div id="page-content" class="clearfix">
        <div class="row-fluid">
            <div class="row-fluid">
                <!-- 检索  -->
                <form action="/role/lst.shtml" method="get" name="userForm" id="userForm">
                    <table>
                        <tr>
                            <td>
						<span class="input-icon">
							<input type="text" name="ROLE_NAME"  placeholder="这里输入关键词" />
							<i id="nav-search-icon" class="icon-search"></i>
						</span>
                            </td>
                            <td style="vertical-align:top;"><button class="btn btn-mini btn-light" onclick="search();" title="检索"><i id="nav-search-icon" class="icon-search"></i></button></td>
                            <td style="vertical-align:top;"><a class="btn btn-mini btn-light" onclick="toExcel();" title="导出到EXCEL"><i id="nav-search-icon" class="icon-download-alt"></i></a></td>
                        </tr>
                    </table>
                    <!-- 检索  -->


                    <table id="table_report" class="table table-striped table-bordered table-hover">
                        <thead>
                        <tr>
                            <th class="center">
                                <label><input type="checkbox" id="zcheckbox" /><span class="lbl"></span></label>
                            </th>
                            <th>序号</th>
                            <th>角色编码</th>
                            <th>角色名称</th>
                            <th>创建时间</th>
                            <th class="center">操作</th>
                        </tr>
                        </thead>
                        <tbody>
                        <#list roles as r>
                        <tr>
                            <td class="center"><label><input type="checkbox" name="ids" value="${r. ROLE_ID}" /><span class="lbl"></span></label></td>
                            <td class='center' style="width: 30px;">${r_index+1}</td>
                            <td>${(r.ROLE_CODE)!}</td>
                            <td>${(r.ROLE_NAME)!}</td>
                            <td class='center'>${(r.create_time)!}</td>
                            <td>
                                <a class='btn btn-mini btn-info' title="编辑" onclick="editUser('${r. ROLE_ID}');"><i class='icon-edit'></i></a>
                                <a class='btn btn-mini btn-danger' title="删除" onclick="delUser('${r. ROLE_ID}','${r.ROLE_NAME}');"><i class='icon-trash'></i></a>
                                <a class="btn btn-mini btn-purple" onclick="editRights('${r.ROLE_ID }');"><i class="icon-pencil"></i>菜单权限</a>
                            </td>
                        </tr>
                        </#list>

                        </tbody>
                    </table>

                    <div class="page-header position-relative">
                        <table style="width:100%;">
                            <tr>
                                <td style="vertical-align:top;">
                                    <a class="btn btn-small btn-success" onclick="add()">新增</a>
                                    <a title="批量删除" class="btn btn-small btn-danger" onclick="makeAll('确定要删除选中的数据吗?');" ><i class='icon-trash'></i></a>
                                </td>
                                <td style="vertical-align:top;"><div class="pagination" style="float: right;padding-top: 0px;margin-top: 0px;">${page}</div></td>
                            </tr>
                        </table>
                    </div>
                </form>
            </div>

            <!-- PAGE CONTENT ENDS HERE -->
        </div><!--/row-->

    </div><!--/#page-content-->
</div><!--/.fluid-container#main-container-->

<!-- 返回顶部  -->
<a href="#" id="btn-scroll-up" class="btn btn-small btn-inverse">
    <i class="icon-double-angle-up icon-only"></i>
</a>

<!-- 引入 -->
<script src="/static/js/bootstrap.min.js"></script>
<script src="/static/js/ace.min.js"></script>
<script type="text/javascript" src="/static/js/chosen.jquery.min.js"></script><!-- 下拉框 -->
<script type="text/javascript" src="/static/js/bootstrap-datepicker.min.js"></script><!-- 日期框 -->
<script type="text/javascript" src="/static/layer-v2.4/layer/layer.js"></script>
<script type="text/javascript" src="/static/js/project/role/role.js"></script>
<script type="text/javascript">
    $(function() {
        //日期框
        $('.date-picker').datepicker();
        //下拉框
        $(".chzn-select").chosen();
        $(".chzn-select-deselect").chosen({allow_single_deselect:true});
    });
</script>

</body>
</html>

